package com.api.gbhg.liuwenbo.version2.pojo;

import java.math.BigDecimal;
import java.util.List;
import java.util.Objects;

/**
 * @Description 预算科收入预算表实体类
 * @Author lwb
 * @Date 2021.12.2
 */
public class BudgetSectionIncome2 {

    private String id; //id
    private String name; //name
    private String kmmc;//科目名称
    private String snjz;//上年结转
    private String bnsr;//本年收入
    private String hj;//合计
    private List<BudgetSectionIncome2> xj;//下级
    private String snjzysap;//上年结转预算安排
    private String bnsrysap;//本年收入预算安排
    private String hj1;//合计
    private String snjzwap;//上年结转未安排
    private String bnsrwap;//本年收入未安排
    private String hj2;//合计
    private String snjzyszc;//上年结转预算支出
    private String bnsryszc;//本年收入预算支出
    private String hj3;//合计
    private String snjzyszxl;//上年结转预算执行率
    private String bnsryszxl;//本年收入预算执行率
    private String hj4;//合计
    private String bnsjsr;//本年实际收入
    private Integer kmjxj;//科目级下级标识 0科目 1下级
    private String dataid;//合并id "1,2,3"
    private String dwName;//单位名称
    private String dwId;//单位id
    private String sjid;//上级id
    private Integer cj;//当前层级
    private String nf;//年份
    private Integer sfxycf; //是否需要拆分

    public Integer getSfxycf() {
        return sfxycf;
    }

    public void setSfxycf(Integer sfxycf) {
        this.sfxycf = sfxycf;
    }

    public String getNf() {
        return nf;
    }

    public void setNf(String nf) {
        this.nf = nf;
    }

    public String getSjid() {
        return sjid;
    }

    public void setSjid(String sjid) {
        this.sjid = sjid;
    }

    public Integer getCj() {
        return cj;
    }

    public void setCj(Integer cj) {
        this.cj = cj;
    }

    public String getDwName() {
        return dwName;
    }

    public void setDwName(String dwName) {
        this.dwName = dwName;
    }

    public String getDwId() {
        return dwId;
    }

    public void setDwId(String dwId) {
        this.dwId = dwId;
    }

    public Integer getKmjxj() {
        return kmjxj;
    }

    public void setKmjxj(Integer kmjxj) {
        this.kmjxj = kmjxj;
    }

    public String getSnjzyszc() {
        return snjzyszc;
    }

    public void setSnjzyszc(String snjzyszc) {
        this.snjzyszc = snjzyszc;
    }

    public String getBnsryszc() {
        return bnsryszc;
    }

    public void setBnsryszc(String bnsryszc) {
        this.bnsryszc = bnsryszc;
    }

    public String getHj3() {
        return hj3;
    }

    public void setHj3(String hj3) {
        this.hj3 = hj3;
    }

    public String getSnjzyszxl() {
        return snjzyszxl;
    }

    public void setSnjzyszxl(String snjzyszxl) {
        this.snjzyszxl = snjzyszxl;
    }

    public String getBnsryszxl() {
        return bnsryszxl;
    }

    public void setBnsryszxl(String bnsryszxl) {
        this.bnsryszxl = bnsryszxl;
    }

    public String getHj4() {
        return hj4;
    }

    public void setHj4(String hj4) {
        this.hj4 = hj4;
    }

    public String getBnsjsr() {
        return bnsjsr;
    }

    public void setBnsjsr(String bnsjsr) {
        this.bnsjsr = bnsjsr;
    }

    public String getSnjzwap() {
        return snjzwap;
    }

    public void setSnjzwap(String snjzwap) {
        this.snjzwap = snjzwap;
    }

    public String getBnsrwap() {
        return bnsrwap;
    }

    public void setBnsrwap(String bnsrwap) {
        this.bnsrwap = bnsrwap;
    }

    public String getHj2() {
        return hj2;
    }

    public void setHj2(String hj2) {
        this.hj2 = hj2;
    }

    public String getHj1() {
        return hj1;
    }

    public void setHj1(String hj1) {
        this.hj1 = hj1;
    }

    public String getSnjzysap() {
        return snjzysap;
    }

    public void setSnjzysap(String snjzysap) {
        this.snjzysap = snjzysap;
    }

    public String getBnsrysap() {
        return bnsrysap;
    }

    public void setBnsrysap(String bnsrysap) {
        this.bnsrysap = bnsrysap;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public List<BudgetSectionIncome2> getXj() {
        return xj;
    }

    public void setXj(List<BudgetSectionIncome2> xj) {
        this.xj = xj;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getKmmc() {
        return kmmc;
    }

    public void setKmmc(String kmmc) {
        this.kmmc = kmmc;
    }

    public String getSnjz() {
        return snjz;
    }

    public void setSnjz(String snjz) {
        this.snjz = snjz;
    }

    public String getBnsr() {
        return bnsr;
    }

    public void setBnsr(String bnsr) {
        this.bnsr = bnsr;
    }

    public String getHj() {
        return hj;
    }

    public void setHj(String hj) {
        this.hj = hj;
    }

    public String getDataid() {
        return dataid;
    }

    public void setDataid(String dataid) {
        this.dataid = dataid;
    }

    public void addSnjz(String snjz){
        this.snjz = new BigDecimal(this.snjz).add(new BigDecimal(snjz)).toString();
    }

    public void addBnsr(String bnsr){
        this.bnsr = new BigDecimal(this.bnsr).add(new BigDecimal(bnsr)).toString();
    }

    public void addHj(String hj){
        this.hj = new BigDecimal(this.hj).add(new BigDecimal(hj)).toString();
    }

    public void addSnjzysap(String snjzysap){
        this.snjzysap = new BigDecimal(this.snjzysap).add(new BigDecimal(snjzysap)).toString();
    }

    public void addBnsrysap(String bnsrysap){
        this.bnsrysap = new BigDecimal(this.bnsrysap).add(new BigDecimal(bnsrysap)).toString();
    }

    public void addHj1(String hj1){
        this.hj1 = new BigDecimal(this.hj1).add(new BigDecimal(hj1)).toString();
    }

    public void addSnjzwap(String snjzwap){
        this.snjzwap = new BigDecimal(this.snjzwap).add(new BigDecimal(snjzwap)).toString();
    }

    public void addBnsrwap(String bnsrwap){
        this.bnsrwap = new BigDecimal(this.bnsrwap).add(new BigDecimal(bnsrwap)).toString();
    }

    public void addHj2(String hj2){
        this.hj2 = new BigDecimal(this.hj2).add(new BigDecimal(hj2)).toString();
    }

    public void addSnjzyszc(String snjzyszc){
        this.snjzyszc = new BigDecimal(this.snjzyszc).add(new BigDecimal(snjzyszc)).toString();
    }

    public void addBnsryszc(String bnsryszc){
        this.bnsryszc = new BigDecimal(this.bnsryszc).add(new BigDecimal(bnsryszc)).toString();
    }

    public void addHj3(String hj3){
        this.hj3 = new BigDecimal(this.hj3).add(new BigDecimal(hj3)).toString();
    }

    public void addSnjzyszxl(String snjzyszxl){
        this.snjzyszxl = new BigDecimal(this.snjzyszxl).add(new BigDecimal(snjzyszxl)).toString();
    }

    public void addBnsryszxl(String bnsryszxl){
        this.bnsryszxl = new BigDecimal(this.bnsryszxl).add(new BigDecimal(bnsryszxl)).toString();
    }

    public void addhj4(String hj4){
        this.hj4 = new BigDecimal(this.hj4).add(new BigDecimal(hj4)).toString();
    }

    public void addDataid(String id){
        this.dataid = this.dataid+","+id;
    }

    public void addDwid(String id){
        this.dwId = this.dwId+","+id;
    }

    public void addId(String id){
        this.id = this.id+","+id;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        BudgetSectionIncome2 that = (BudgetSectionIncome2) o;
        return Objects.equals(kmmc, that.kmmc);
    }

    public boolean equals2(BudgetSectionIncome2 o) {
        return this.getKmmc().equals(o.getKmmc()) && this.getName().equals(o.getName());
    }

}
